import { createApp } from 'vue'
import { createPinia } from 'pinia'
import App from './App.vue'
// import piniaPluginPersistedstate from 'pinia-plugin-persistedstate'
import { createPersistedState } from 'pinia-plugin-persistedstate'
import router from './router'
import 'element-plus/theme-chalk/src/message.scss'
import 'element-plus/theme-chalk/src/index.scss'
import PaoMadeng from './components/PaoMadeng.vue'
// 引入mockjs模拟的接口和数据
import './mock/index'
import './mock/order'
import './mock/user'
import './mock/mounted'
// import './assets/main.css'
//引入mockjs模拟商品页的接口和数据
import './mock/goods.js'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'
const app = createApp(App);
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
    app.component(key, component)
}
var store = createPinia();

store.use(createPersistedState());
app.use(store);


app.use(router)
app.use('PaoMadeng',PaoMadeng)
app.mount('#app')